1. Technical Field
The present invention relates in general to an improved data processing system and in particular to an improved method and system for managing events in a graphic user interface. Still more particularly, the present invention relates to a method and system for managing events in a graphic user interface in a manner independent of the environment.
2. Description of the Related Art
The development of application and system software for data processing systems has traditionally been a time consuming task. The field of software engineering has attempted to overcome the limitations of traditional techniques by proposing new, more efficient software development models. Object oriented programming has emerged as a promising technology that will allow rapid development, implementation and customization of objects. Each new object has certain data attributes and processes or methods that operate on that data. Data is said to be "encapsulated" by an object and can only be modified by the object methods are invoked by sending a message to an object identifying the method and supplying any needed arguments.
Object oriented systems have two important properties in addition to encapsulation. "Inheritance" is the ability to derive a new object from an existing object and inherit all properties, including methods and data structure, from the existing object. The new object may have certain unique features which are supplied as overrides or modifications to the existing class. For example, a new subclass needs to specify only the functions and data that distinguish that class from the existing more general class.
The ability to override an existing method description enables polymorphism, the ability to have a single message to an object be processed in different ways depending on the object itself.
Inheritance and polymorphism create a powerful structure for implementing new software systems. The software developer does not have to develop each piece of a system, he or she need only specify the unique features of the system.
The power of object oriented systems is realized through the development of system "frameworks." A framework is a collection of base classes that can be used by a system implementor to create a final systems product. The framework is defined and developed to work together as a system. Conceptually, the framework is much like a set of standard hardware components used by computer hardware builders. Each of the components has certain defined functions and interfaces and the engineer assembles these components according to a particular design to create a unique hardware system.
One object oriented programming system is the System Object Model (SOM). More information on SOM can be found in SOMobjects Developer Toolkit Users Guide, version 2.0, June 1993, available from International Business Machines Corporation.
In object oriented system and others, data may be manipulated in many ways in a data processing system including: data accessing; data encoding; data communication; data compression; data conversion; data entry; data exchange; data filing; data linking; data locking; data manipulation; data mapping; data recording; data sorting; and data transferring. The large amounts of data which are available to the user of a data processing system often become overwhelming in magnitude and complexity.
As a result of the increasing complexity of data processing systems, attempts have been made to simplify the interface between a user and the large amounts of data present within a data processing system. One example of an attempt to simplify the interface between a user and a data processing system is the use of a so-called Graphical User Interface (GUI) to provide an intuitive and graphical interface between the user and the data processing system. A graphic user interface includes a collection of graphic icons, menus, clipboards, desk accessories, and alert boxes, each accessible through the use of a mouse. The Common User Access (CUA) interface is one example of such a GUI. Common User Access and CUA are trademarks of International Business Machines Corporation. The Common User Access interface is often employed to organize and present large amounts of data to a user in a graphical and intuitive manner. More information on Common User Access interface may be found in Systems Application Architecture Common User Access Interface Design available from International Business Machines Corporation, publication no. SC34-42900-00.
Management of events drive the flow of control in GUI programming. Each event may have associated actions, which need to be performed for that particular event. An event management system has the responsibility to recognize and perform (dispatch) the associated action.
Two types of events exist: external (physical) and internal (logical). External events are generated by some physical device, such as a mouse, keyboard, touch screen, or the like. On the other hand, internal events are generated by some logic, such as a program or object. The internal events are typically generated by modules within programs executing in a data processing system. As cross-platform programming becomes more and more desirable, platform independent event management becomes very important in event driven systems, i.e. OS/2, AIX from IBM, and Windows, NT, and Windows95 from Microsoft Corporation.
Typically each platform has its own event management system. Since event management drives the flow control of the program, other code in a data processing system can easily become depend on that given event management. For example, a drag action; under OS/2 starts by depressing a right mouse button and moving the mouse. Under windows, a drag action begins by depressing the left mouse button and moving the mouse; under AIX, a drag action begins by depressing the middle mouse button and moving the mouse. "OS/2" is a trademark of International Business Machines Corporation; AIX is International Business Machines' implementation of UNIX, a trademark of UNIX System Laboratories, Inc. "AIX" is a trademark of International Business Machines Corporation. In this case, if the recognition of a drag event is not isolated at the event management level, three different versions of code for drag action with each version of the code being depend on each one of the platforms, also called "environments".
Therefore, it would be advantageous to have a method and system for providing platform specific event recognition in a event management system that is environment independent.